/* ***********************************************************************
 * Copyright (C) 1992-- 2016 中国南方航空股份有限公司.
 *
 * Created [2016-09-08 14:35:36] by FMS Team
 * ***********************************************************************
 *
 * mybaits-generator
 * ***********************************************************************
 */
package com.foreveross.law.contract.domain;

import org.apache.commons.lang3.builder.EqualsBuilder;
import org.apache.commons.lang3.builder.HashCodeBuilder;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
* <p>com.foreveross.law.contract.domain.ContractMessageBook</p>
*
* @author changwu.liao email:changwu.liao(a)gmail.com
* @version 1.0
* @since 1.0
* @Modified by add modified description
* @purpose add this file description here
*/
public class ContractMessageBook implements java.io.Serializable{
	private static final long serialVersionUID = 5454155825314635342L;
	
	//alias	
	public static final String TABLE_SQL_NAME = "CONTRACT_MESSAGE_BOOK";
	
	public static final String ALIAS_CONTRACT_MESSAGE_BOOK_ID = "contractMessageBookId";
	public static final String ALIAS_CONTRACT_ID = "contractId";
	public static final String ALIAS_WORK_FLOW_ID = "workFlowId";
	public static final String ALIAS_SEND_TO = "sendTo";
	public static final String ALIAS_MESSAGE_CONTENT = "messageContent";
	public static final String ALIAS_CREATE_DATE = "createDate";
	public static final String ALIAS_CREATE_BY = "createBy";
	
	//the column is a primary key	
	public static final String PROP_KEY = "contractMessageBookId";
	
	//fields START
	public static String PROP_REF="ContractMessageBook";
	public static String PROP_REF_CONTRACT_MESSAGE_BOOK_ID = "contractMessageBookId";
	
	public static String PROP_REF_CONTRACT_ID = "contractId";
	
	public static String PROP_REF_WORK_FLOW_ID = "workFlowId";
	
	public static String PROP_REF_SEND_TO = "sendTo";
	
	public static String PROP_REF_MESSAGE_CONTENT = "messageContent";
	
	public static String PROP_REF_CREATE_DATE_BEGIN = "createDateBegin";
	public static String PROP_REF_CREATE_DATE_END = "createDateEnd";
	
	public static String PROP_REF_CREATE_BY = "createBy";
	
	//fields END
	
	//columns sql name START	
	public static String PROP_COLUMN_CONTRACT_MESSAGE_BOOK_ID = "CONTRACT_MESSAGE_BOOK_ID";
	public static String PROP_COLUMN_CONTRACT_ID = "CONTRACT_ID";
	public static String PROP_COLUMN_WORK_FLOW_ID = "WORK_FLOW_ID";
	public static String PROP_COLUMN_SEND_TO = "SEND_TO";
	public static String PROP_COLUMN_MESSAGE_CONTENT = "MESSAGE_CONTENT";
	public static String PROP_COLUMN_CREATE_DATE = "CREATE_DATE";
	public static String PROP_COLUMN_CREATE_BY = "CREATE_BY";
	//columns sql name END
		
	//columns START
	private java.lang.String contractMessageBookId;
	private java.lang.String contractId;
	private java.lang.String workFlowId;
	private java.lang.String sendTo;
	private java.lang.String messageContent;
	private java.util.Date createDate;
	private java.lang.String createBy;
	//columns END

	public ContractMessageBook(){
	}

	public ContractMessageBook(
		java.lang.String contractMessageBookId
	){
		this.contractMessageBookId = contractMessageBookId;
	}

	public void setContractMessageBookId(java.lang.String value) {
		this.contractMessageBookId = value;
	}
	
	public java.lang.String getContractMessageBookId() {
		return this.contractMessageBookId;
	}
	public void setContractId(java.lang.String value) {
		this.contractId = value;
	}
	
	public java.lang.String getContractId() {
		return this.contractId;
	}
	public void setWorkFlowId(java.lang.String value) {
		this.workFlowId = value;
	}
	
	public java.lang.String getWorkFlowId() {
		return this.workFlowId;
	}
	public void setSendTo(java.lang.String value) {
		this.sendTo = value;
	}
	
	public java.lang.String getSendTo() {
		return this.sendTo;
	}
	public void setMessageContent(java.lang.String value) {
		this.messageContent = value;
	}
	
	public java.lang.String getMessageContent() {
		return this.messageContent;
	}
	
	public void setCreateDate(java.util.Date value) {
		this.createDate = value;
	}
	
	public java.util.Date getCreateDate() {
		return this.createDate;
	}
	public void setCreateBy(java.lang.String value) {
		this.createBy = value;
	}
	
	public java.lang.String getCreateBy() {
		return this.createBy;
	}

	public String toString() {
		return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
			.append("ContractMessageBookId",getContractMessageBookId())
			.append("ContractId",getContractId())
			.append("WorkFlowId",getWorkFlowId())
			.append("SendTo",getSendTo())
			.append("MessageContent",getMessageContent())
			.append("CreateDate",getCreateDate())
			.append("CreateBy",getCreateBy())
			.toString();
	}
	
	public int hashCode() {
		return new HashCodeBuilder()
			.append(getContractMessageBookId())
			.toHashCode();
	}
	
	public boolean equals(Object obj) {
		if(obj instanceof ContractMessageBook == false) return false;
		if(this == obj) return true;
		ContractMessageBook other = (ContractMessageBook)obj;
		return new EqualsBuilder()
			.append(getContractMessageBookId(),other.getContractMessageBookId())
			.isEquals();
	}
}

